package thread.pipe_stream;

import java.io.PipedOutputStream;

/**
 * Created by mHandler on 2018/6/2 0002.
 * Description:
 */
public class WriteThread extends Thread {
    private WriteData writeData;
    private PipedOutputStream outputStream;
    public WriteThread(WriteData writeData,PipedOutputStream outputStream){
        super();
        this.outputStream =outputStream;
        this.writeData=writeData;
    }

    @Override
    public void run() {
        super.run();
        writeData.writeMethod(outputStream);
    }
}
